<template>
  <div id="app">
    <h1>购物车</h1>
    <Table :arr='list' :quan="quan"/>
  </div>
</template>

<script>
import Table from "./components/table.vue";

export default {
  name: "App",
  components: {
    Table,
  },
  data() {
    return {
      list: [
        {
          id: 1,
          name: "小米",
          price: 1500,
          num: 1,
          znum:1500,
          zhuangtai: false,
        },
        {
          id: 2,
          name: "小米1",
          price: 2500,
          num: 1,
          znum:2500,
          zhuangtai: false,
        },
        {
          id: 3,
          name: "小米2",
          price: 3500,
          num: 1,
          znum:3500,
          zhuangtai: false,
        },
      ],
      quan: false,
      zhong: 0,
    };
  },
};
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
